/*
 * Fichier: JavaExos.java
 * Crée le: 07 mai 2007.
 * Modifié: 14 février 2009.
 * Auteurs: Sébastien ESTIENNE.
 * SiteWeb: http://www.prog-info.org/
 * 
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 * 
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 */

package javaexos.main;



import javaexos.gui.GuiViewFactory;
import javaexos.gui.main.SplashWindow;
import javaexos.io.XMLFileBook;
import javaexos.view.ViewFactory;



/**
 * <p>Lance l'application des exercices en Java.</p>
 * @author Sébastien ESTIENNE.
 */
public class JavaExos
{
   /**
    * <p>Débute l'exécution du programme.</p>
    * @param args Les paramètres de la ligne de commande.
    */
   public static void main(String[] args)
   {
      // Lancement du splash.
      SplashWindow splash = new SplashWindow();
      
      // Chargement des chapitres.
      XMLFileBook book = new XMLFileBook();
      book.addChapterListener(splash);
      book.loadChapters();
      
      // Lancement de l'aplication.
      ViewFactory factory = new GuiViewFactory();
      new JavaExosFrameController(splash, book, factory);
   }
}
